home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / modules / nessus-2.2.8.mo / usr / lib / nessus / plugins / keene_xss.nasl < prev    next >
Text File  |  2005-03-31  |  3KB  |  91 lines

  1. #
  2. # This script was written by David Maciejak <david dot maciejak at kyxar dot fr>
  3. # Ref: Dr_insane
  4. #
  5. # This script is released under the GNU GPL v2
  6.  
  7. if(description)
  8. {
  9.   script_id(14681);
  10.   script_bugtraq_id(11111);
  11.   if ( defined_func("script_xref") ) 
  12.   {
  13.     script_xref(name:"OSVDB", value:9514);
  14.     script_xref(name:"OSVDB", value:9515);
  15.     script_xref(name:"OSVDB", value:9516);
  16.   }
  17.   script_version("$Revision: 1.4 $");
  18.   
  19.   script_name(english:"Keene digital media server XSS");
  20.  
  21.  
  22.  desc["english"] = "
  23. The remote host runs Keene digital media server, a webserver
  24. used to share digital information.
  25.  
  26.  
  27. This version is vulnerable to multiple cross-site scripting attacks which
  28. may allow an attacker to steal the cookies of users of this site.
  29.  
  30. Solution: Upgrade to the latest version of this software
  31. Risk factor : Medium";
  32.  
  33.   script_description(english:desc["english"]);
  34.   script_summary(english:"Checks XSS in Keene server");
  35.   script_category(ACT_GATHER_INFO);
  36.   script_copyright(english:"This script is Copyright (C) 2004 David Maciejak");
  37.   script_family(english:"CGI abuses : XSS");
  38.   script_require_ports("Services/www", 80);
  39.   script_dependencie("http_version.nasl", "cross_site_scripting.nasl");
  40.   exit(0);
  41. }
  42.  
  43. include("http_func.inc");
  44. include("http_keepalive.inc");
  45.  
  46. port = get_http_port(default:80);
  47. if(!get_port_state(port))exit(0);
  48. if ( get_kb_item("www/" + port + "/generic_xss") ) exit(0);
  49.  
  50. buf = http_get(item:"/dms/slideshow.kspx?source=<script>foo</script>", port:port);
  51. r = http_keepalive_send_recv(port:port, data:buf, bodyonly:1);
  52. if( r == NULL )exit(0);
  53.  if(egrep(pattern:"<script>foo</script>", string:r))
  54.   {
  55.      security_warning(port);
  56.     exit(0);
  57.   }
  58. buf = http_get(item:"/dms/dlasx.kspx?shidx=<script>foo</script>", port:port);
  59. r = http_keepalive_send_recv(port:port, data:buf, bodyonly:1);
  60. if( r == NULL )exit(0);
  61.   if(egrep(pattern:"<script>foo</script>", string:r))
  62.   {
  63.      security_warning(port);
  64.     exit(0);
  65.   }
  66. buf = http_get(item:"/igen/?pg=dlasx.kspx&shidx=<script>foo</script>", port:port);
  67.  r = http_keepalive_send_recv(port:port, data:buf, bodyonly:1);
  68. if( r == NULL )exit(0);
  69. if(egrep(pattern:"<script>foo</script>", string:r))
  70.   {
  71.      security_warning(port);
  72.     exit(0);
  73.   }
  74. buf = http_get(item:"/dms/mediashowplay.kspx?pic=<script>foo</script>&idx=0", port:port);
  75.  r = http_keepalive_send_recv(port:port, data:buf, bodyonly:1);
  76. if( r == NULL )exit(0);
  77.  if(egrep(pattern:"<script>foo</script>", string:r))
  78.   {
  79.      security_warning(port);
  80.     exit(0);
  81.   }
  82. buf = http_get(item:"/dms/mediashowplay.kspx?pic=0&idx=<script>foo</script>", port:port);
  83. r = http_keepalive_send_recv(port:port, data:buf, bodyonly:1);
  84. if( r == NULL )exit(0);
  85. if(egrep(pattern:"<script>foo</script>", string:r))
  86.   {
  87.      security_warning(port);
  88.     exit(0);
  89.   }
  90.